﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MoetutuTranslate.Helper
{
    class StaticValue
    {
        private static string tip = "当前无任务";
        private static int progressCount = 0;
        private static string userAgent = "Mozilla/5.0 (Windows NT 10.0; WOW64; rv:56.0) Gecko/20100101 Firefox/56.0";
        private static string tempPath = ".\\TempPath\\";
        private static string binPath = ".\\Bin\\";
        private static string xmlPath = BinPath + "Tags.xml";
      private static List<TagStruct> tagStruct =TagHelper.XmlReadAll(XmlPath);
        private static string excludePath = BinPath + "ExcludeKeys.txt";
        private static string lockTag = BinPath + "Lock.txt";
        private static List<string> excludeList = FileHelper.ReadTextAllLine(excludePath);
        private static List<string> lockTagList = FileHelper.ReadTextAllLine(LockTag);
        private static List<string> jpTagList = TagHelper.XMLReadJp(TagStruct);
        private static int timeLockNum = DateTime.Now.Second;
        /// <summary>
        /// 提示信息
        /// </summary>
        public static string Tip { get => tip; set => tip = value; }

        /// <summary>
        /// 进度条的值
        /// </summary>
        public static int ProgressCount { get => progressCount; set => progressCount = value; }
        public static string UserAgent { get => userAgent; set => userAgent = value; }
        public static string TempPath { get => tempPath; set => tempPath = value; }
        public static string BinPath { get => binPath; set => binPath = value; }
        public static string XmlPath { get => xmlPath; set => xmlPath = value; }
        public static List<TagStruct> TagStruct { get => tagStruct; set => tagStruct = value; }
        /// <summary>
        /// 屏蔽关键词的路径
        /// </summary>
        public static string ExcludePath { get => excludePath; set => excludePath = value; }
        /// <summary>
        /// 存放锁定文件的路径
        /// </summary>
        public static string LockTag { get => lockTag; set => lockTag = value; }
        /// <summary>
        /// 需要锁定，加入黑名单（不在扫描）的tag
        /// </summary>
        public static List<string> LockTagList { get => lockTagList; set => lockTagList = value; }
        /// <summary>
        /// 已经有对应汉化的日本tag
        /// </summary>
        public static List<string> JpTagList { get => jpTagList; set => jpTagList = value; }
        /// <summary>
        /// 黑名单的列表
        /// </summary>
        public static List<string> ExcludeList { get => excludeList; set => excludeList = value; }
        /// <summary>
        /// 时间锁
        /// </summary>
        public static int TimeLockNum { get => timeLockNum; set => timeLockNum = value; }
    }
}
